package com.edu.test.commandPattern;

/**
 * @作者 five-five
 * @创建时间 2020/12/26
 */
public class ConcreteCommandB extends Command {

    public ConcreteCommandB(Reciver reciver) {
        System.out.println("revicer的首地址:" + reciver.hashCode());
        super.reciver = reciver;
    }

    public ConcreteCommandB() {
    }

    @Override
    public void exceute() {
        try {
            System.out.println(this.getClass().getMethod("exceute") + "执行........");
            super.reciver.action();
        } catch (NoSuchMethodException e) {
            e.printStackTrace();
        }
    }
}
